<template>
  <div>
    <div class="botDetail" v-if="showItem">
      <div class="banner">
        <div class="bannerMain">
          <div>
            <div class="botName">
              <img :src="item.imgUrl" />
              <div>
                {{ item.name }}
              </div>
            </div>
            <div class="botDesc">
              {{ item.desc }}
            </div>
            <div class="bottonBox" v-for="items in item.bottonBoxs">
              <div>{{ items.txt }}</div>
              <div>{{ items.txt1 }}</div>
              <div>{{ items.txt2 }}</div>
            </div>
            <div class="notice"></div>
          </div>
          <img :src="item.imgUrl1" />
        </div>
      </div>
      <div class="character">
        <div class="characterMain">
          <div class="itemTitle">
            <div class="mainTitle">
              <div class="line"></div>
              <div class="centerTitle">产品特性</div>
              <div class="line"></div>
            </div>
            <div class="subTitle">Product features</div>
          </div>
          <div class="characterList">
            <div v-for="e in item.characterItems">
              <div class="characterItem">
                <div class="item-image">
                  <img :src="e.imgUrl" />
                </div>
                <div class="item-info">
                  <p>
                    {{ e.txt }}
                  </p>
                  <p>
                    {{ e.txt1 }}
                  </p>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <div class="Workflow">
        <div class="itemTitle">
          <div class="mainTitle">
            <div class="line"></div>
            <div class="centerTitle">工作流程图</div>
            <div class="line"></div>
          </div>
          <div class="subTitle">Workflow</div>
        </div>
        <div class="WorkflowImg">
          <img :src="item.imgUrl2" />
        </div>
      </div>
      <div>
        <div class="case">
          <div class="caseMain">
            <div class="itemTitle">
              <div class="mainTitle">
                <div class="line"></div>
                <div class="centerTitle">客户案例</div>
                <div class="line"></div>
              </div>
              <div class="subTitle">Customer case</div>
            </div>
            <div class="caseList">
              <div class="lastCase" v-for="c in item.caseLists">
                <img :src="c.imgUrl" />
                <p class="caseTitle">
                  {{ c.title }}
                </p>
                <p>
                  {{ c.desc }}
                </p>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      item: {},
      showItem: true,
      botDetails: [
        {
          id: 200001,
          imgUrl: require("@/static/jiqiren.png"),
          name: "Steam礼物机器人-淘宝版",
          desc:
            "Steam礼物机器人(淘宝版)适用于淘宝/天猫平台游戏代购店铺自动发货，帮助商家实现24小时Steam游戏代购自动发货，和每天重复上百次的发货工作说再见。",
          bottonBoxs: [{ txt: "立即购买", txt1: "点我试用", txt2: "产品文档" }],
          imgUrl1: require("@/static/bot-1.png"),
          characterItems: [
            {
              imgUrl: require("@/static/character.png"),
              txt: "支持多钱包同时发货",
              txt1:
                "支持给各钱包指定线路，分开IP登陆，自动更换钱包发货，几秒一单。",
            },
          ],
          imgUrl2: require("@/static/work.png"),
          caseLists: [
            {
              imgUrl: require("@/static/anli.png"),
              title: "浩瀚数码专营店",
              desc:
                "浩瀚数码专营店主营多平台游戏代购，包含Steam，Origin，Epic，Uplay。使用steam礼物代购机器人，帮助商家实现24小时Steam游戏代购自动发货，大大提供代购效率，降低了人工成本",
            },
          ],
        },
        {
          id: 200002,
          imgUrl: require("@/static/jiqiren.png"),
          name: "Steam礼物机器人-激活码版",
          desc:
            "Steam礼物机器人(淘宝版)适用于淘宝/天猫平台游戏代购店铺自动发货，帮助商家实现24小时Steam游戏代购自动发货，和每天重复上百次的发货工作说再见。",
          bottonBoxs: [{ txt: "立即购买", txt1: "点我试用", txt2: "产品文档" }],
          imgUrl1: require("@/static/bot-1.png"),
          characterItems: [
            {
              imgUrl: require("@/static/character.png"),
              txt: "支持多钱包同时发货",
              txt1:
                "支持给各钱包指定线路，分开IP登陆，自动更换钱包发货，几秒一单。",
            },
          ],
          imgUrl2: require("@/static/work.png"),
          caseLists: [
            {
              imgUrl: require("@/static/anli.png"),
              title: "浩瀚数码专营店",
              desc:
                "浩瀚数码专营店主营多平台游戏代购，包含Steam，Origin，Epic，Uplay。使用steam礼物代购机器人，帮助商家实现24小时Steam游戏代购自动发货，大大提供代购效率，降低了人工成本",
            },
          ],
        },
        {
          id: 200003,
          imgUrl: require("@/static/jiqiren.png"),
          name: "Steam饰品机器人-淘宝版",
          desc:
            "Steam礼物机器人(淘宝版)适用于淘宝/天猫平台游戏代购店铺自动发货，帮助商家实现24小时Steam游戏代购自动发货，和每天重复上百次的发货工作说再见。",
          bottonBoxs: [{ txt: "立即购买", txt1: "点我试用", txt2: "产品文档" }],
          imgUrl1: require("@/static/bot-1.png"),
          characterItems: [
            {
              imgUrl: require("@/static/character.png"),
              txt: "支持多钱包同时发货",
              txt1:
                "支持给各钱包指定线路，分开IP登陆，自动更换钱包发货，几秒一单。",
            },
          ],
          imgUrl2: require("@/static/work.png"),
          caseLists: [
            {
              imgUrl: require("@/static/anli.png"),
              title: "浩瀚数码专营店",
              desc:
                "浩瀚数码专营店主营多平台游戏代购，包含Steam，Origin，Epic，Uplay。使用steam礼物代购机器人，帮助商家实现24小时Steam游戏代购自动发货，大大提供代购效率，降低了人工成本",
            },
          ],
        },
      ],
    };
  },
  created() {
    const id = this.$route.query.id;
    this.item = this.botDetails.find((s) => String(s.id) === String(id));
  },
  watch: {
    $route: {
      handler() {
        const id = this.$route.query.id;
        if (id != undefined) {
          this.item = this.botDetails.find((s) => String(s.id) === String(id));
        }
      },
      deep: true,
    },
  },
};
</script>

<style lang="less" scoped>
.botDetail {
  width: 100%;
  min-height: 100vh;
  background: #f5f5f5;
  box-sizing: border-box;
  .banner {
    width: 100%;
    height: 548px;
    background-color: #2e2f3a;
    background-image: url(../static/mianfei.png);
    background-repeat: no-repeat;
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    .bannerMain {
      width: 1200px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      .botName {
        display: flex;
        align-items: center;
        font-size: 40px;
        font-family: Microsoft YaHei;
        font-weight: 700;
        color: #fff;
        img {
          width: 44px;
          height: 44px;
          margin-right: 17px;
        }
      }
      .botDesc {
        width: 662px;
        font-size: 14px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        color: #fff;
        margin-top: 48px;
      }
      .bottonBox {
        display: flex;
        margin-top: 48px;
        > div {
          width: 112px;
          height: 42px;
          border: 1px solid #fff;
          border-radius: 4px;
          line-height: 42px;
          text-align: center;
          margin-right: 40px;
          cursor: pointer;
          font-size: 14px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #fff;
        }
        > div:first-child {
          background: #1768e4;
          border: none;
        }
      }
      .notice {
        font-style: 14px;
        font-family: Microsoft YaHei;
        color: #dd0f0f;
        margin-top: 20px;
      }
      img {
        width: 270px;
        height: 270px;
      }
    }
  }
  .character {
    background: #fff;
    box-sizing: border-box;
    padding: 20px 0;
    .characterMain {
      width: 1200px;
      margin: 46px auto 0;
      .itemTitle {
        display: flex;
        flex-direction: column;
        align-items: center;
        .mainTitle {
          display: flex;
          align-items: center;
          font-size: 30px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #282828;
          .line {
            width: 56px;
            height: 1px;
            background: #e5e5e5;
          }
          .centerTitle {
            margin: 0 16px;
          }
          .whiteTitle {
            color: #fff;
          }
        }
        .subTitle {
          font-size: 18px;
          font-family: PingFang SC;
          font-weight: 400;
          color: #999;
          margin-top: 9px;
        }
      }
      .characterList {
        margin-top: 42px;
        display: flex;
        flex-wrap: wrap;
        > div {
          width: 33.3%;
          margin-bottom: 40px;
          .characterItem {
            display: flex;
            justify-content: center;
            align-items: center;
            .item-image {
              width: 80px;
              height: 80px;
              margin-right: 20px;
              img {
                width: 100%;
              }
            }
            .item-info {
              font-size: 14px;
              font-family: Microsoft YaHei;
              font-weight: 400;
              color: #999;
              width: 224px;
              p:first-child {
                font-size: 18px;
                font-family: Microsoft YaHei;
                font-weight: 700;
                color: #222;
                margin-bottom: 10px;
              }
              p:last-child {
                height: 60px;
                line-height: 20px;
                overflow: hidden;
                display: -webkit-box;
                text-overflow: ellipsis;
                -webkit-line-clamp: 3;
                -webkit-box-orient: vertical;
              }
            }
          }
        }
      }
    }
  }
  .Workflow {
    margin-top: 71px;
    .itemTitle {
      display: flex;
      flex-direction: column;
      align-items: center;
      .mainTitle {
        display: flex;
        align-items: center;
        font-size: 30px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        color: #282828;
        .line {
          width: 56px;
          height: 1px;
          background: #e5e5e5;
        }
        .centerTitle {
          margin: 0 16px;
        }
        .whiteTitle {
          color: #fff;
        }
      }
      .subTitle {
        font-size: 18px;
        font-family: PingFang SC;
        font-weight: 400;
        color: #999;
        margin-top: 9px;
      }
    }
    .WorkflowImg {
      width: 1200px;
      margin: 30px auto 0;
      display: flex;
      align-items: center;
      justify-content: center;
      img {
        max-width: 100%;
      }
    }
  }
  .case {
    width: 100%;
    min-height: 521px;
    background: #fff;
    box-sizing: border-box;
    padding: 71px 0 98px;
    margin-top: 71px;
    .caseMain {
      width: 1200px;
      margin: 0 auto;
      .itemTitle {
        display: flex;
        flex-direction: column;
        align-items: center;
        .mainTitle {
          display: flex;
          align-items: center;
          font-size: 30px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #282828;
          .line {
            width: 56px;
            height: 1px;
            background: #e5e5e5;
          }
          .centerTitle {
            margin: 0 16px;
          }
          .whiteTitle {
            color: #fff;
          }
        }
        .subTitle {
          font-size: 18px;
          font-family: PingFang SC;
          font-weight: 400;
          color: #999;
          margin-top: 9px;
        }
      }
      .caseList {
        margin-top: 43px;
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        .lastCase {
          border: none;
        }
        > div {
          width: 25%;
          display: flex;
          flex-direction: column;
          align-items: center;
          font-size: 12px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #666;
          box-sizing: border-box;
          padding: 35px;
          line-height: 25px;
          margin-bottom: 20px;
          border-right: 1px solid #e5e5e5;
          cursor: pointer;
          img {
            width: 100%;
            height: 111px;
          }
          p {
            width: 100%;
            text-align: left;
          }
          .caseTitle {
            font-size: 14px;
            font-family: Microsoft YaHei;
            font-weight: 700;
            color: #222;
            margin-top: 28px;
          }
        }
      }
    }
  }
}
</style>